package com.etc.controller;

import com.etc.entity.Orders;
import com.etc.service.OrderService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;

@RequestMapping("/orderController")
public class OrderController {

    @Autowired
    OrderService orderService;

    @GetMapping("/insertOrder")
    public Orders insertOrder(Orders order){
        Orders order1 = orderService.addOrder(order);
        return order1;
    }
}
